
/*自己命名*/
;$.fn.tableColor = function(options){
	var defaults = {
		//1.各种参数及属性
		evenClass:'evenRow',
		oddClass:'oddRow',
		mouseOverClass:'mouseOverRow',
		eventType:'mouseover',
		eventType2:'mouseout'
	}
	var options = $.extend(defaults,options);//2.把申明的参数与属性合并到options中去
	this.each(function(){
		//3.实现功能的代码
		var _this = $(this);
		_this.find("tr:even").addClass(options.evenClass);
		
		_this.find("tr:odd").addClass(options.oddClass);
		
		_this.find('tr').bind(options.eventType,function(){
			$(this).addClass(options.mouseOverClass);
		}).bind(options.eventType2,function(){
			$(this).removeClass(options.mouseOverClass);
		});
		
	});
	
}